package com.example.sbtest.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/testDefault")
public class test01 {


    //查询用户信息
    @GetMapping("/selectUser")
    public String selectUser(@RequestParam String name) {
        if (name.equals("张三")) {
            return "我是张三同学";
        } else {
            return "我是李四同学";
        }
    }
}
